const http = uni.$u.http
function getConfig(config) {
    return {
        ...config,
        header: {
            Accept: 'application/json'
        }
    }
}
// post请求，获取菜单
export default {
    getMenuList: (data) => {
        return http.get('/category/list', data, getConfig())
    },
    getAreaList: (data) => {
        return http.get('/area/list', data, getConfig())
    },
    getGoodsList: (data) => {
        return http.get('/goods', data, getConfig())
    },
    getConditionList: (data) => {
        return http.get('/condition/list', data, getConfig())
    },
    getGoodsDetail: (data) => {
        return http.get('/goods/' + data.id, data, getConfig())
    },
    getTagList: (data) => {
        return http.get('/tag/list', data, getConfig())
    }
}